package engine.tip.tipItem
{
	import engine.data.ObjectData;
	
	import newx.com.config.StaticIni;

	/**
	 *药品tips 
	 * @author yanghr
	 * 
	 */	
	public class MedicineItem extends NormalItem
	{
		public function MedicineItem(dataObject:ObjectData=null, data:Object=null)
		{
			super(dataObject, data);
		}
		override public function getAppendEffect():String
		{
			var WeakenValue:int	= _data["WeakenValue"];
			var weakCount:int	= _data["weakTime"];
			var tips:String = "";
			if(String(_data["AddPropertyName"]).indexOf(",") == -1){
				var propertyName:String		= _data["AddPropertyName"];
				var propertyValue:int		= _data["AddPropertyValue"];
				tips = StaticIni.getSwfLangStrVar("Item_" + propertyName,[(propertyValue - WeakenValue * weakCount)]);
			} else {
				var proNameArr:Array	= String(_data["AddPropertyName"]).split(",");
				var addArr:Array		= String(_data["AddPropertyValue"]).split(",");
				tips += StaticIni.getSwfLangStrVar("Item_"+ proNameArr.shift(),[(addArr.shift() - WeakenValue * weakCount)]) + getChangeLine();
				tips += StaticIni.getSwfLangStrVar("Item_"+ proNameArr.shift(),[(addArr.shift() - WeakenValue * weakCount)]);
			}
			return getPropertyColor(tips) + getChangeLine();
		}
	}
}